﻿@using WebEntities;
@using Tools.com.Pager;
@model PagedList<PP_Product>

@{
    ViewBag.Title = "产品信息_城市垃圾处理网";
    ViewBag.ClassHead = "head_bg8";
}

<div class="listMain">
    <div class="main_l">
        <div class="contentBox">
            <div class="searchArea">
            @using (Html.BeginForm("searchproduct", "list"))
            {
                <div class="tit">
                    查找产品</div>
                <input type="text" name="search" id="search" value="@ViewBag.SearchKey" maxlength="20" placeholder = "请输入搜索内容" class="txtInp" />
                <select name="stype">
                    <option value="prodName">按产品名称查找</option>
                    <option value="prodDescr">按产品描述查找</option>
                </select>
                <input type="submit" value="" class="btnSearch" />
            }
            </div>
        </div>
         @Html.Action("Contact", "PublicPartialView")
    </div>
    <div class="main_r">
        <div class="addressRemark">
            您当前位置：<a href="/">首页</a> > <a href="#">查找产品</a>
        </div>
        <div class="contentBox">
            <div class="tab">
                <ul>
                    <li class="current">查找结果</li>
                </ul>
                <span class="subitem">一共找到<font class="red">@ViewBag.SearchCount</font>种产品</span>
            </div>
            <div class="tab-content">
                @foreach (PP_Product obj in Model)
                {
                    <dl class="picList-show">
                        <dt><a href="/detail/product/@obj.ProductID" target="_blank" title="">
                            <img src="@obj.ProductCover" width="95px" height="70" alt="" /></a></dt>
                        <dd>
                            <div class="tit">
                                <a href="/detail/product/@obj.ProductID" target="_blank" title="">@obj.ProductName</a>
                            </div>
                            <p class="gray">
                               @{
                                    string htmlDescr = Server.HtmlDecode(obj.Description);
                                    string plainDescr = WebsiteUI.Extensions.HtmlWorkshop.StripHtml(htmlDescr ?? string.Empty);
                                }
                                @Html.Raw(WebsiteUI.Extensions.HtmlWorkshop.CutTitle(plainDescr, 85))
                               </p>
                            <div class="">
                              产品目录:@(obj.PP_ProductCata != null ? obj.PP_ProductCata.ProdCataName : string.Empty) &nbsp;&nbsp; 创建时间：@obj.CreateTime.ToString("yyyy-MM-dd HH:mm")   &nbsp;&nbsp; 产品类别: @obj.ProductType</div>
                        </dd>
                        <div class="cls">
                        </div>
                    </dl>
                }
                @Html.Pager(Model, new PagerOptions
{
    PageIndexParameterName = "page",
    CssClass = "mvc-pager",
    CurrentPagerItemWrapperFormatString = "<a  href='javascript:void(0)' class=\"mvc-paged\">{0}</a>",
    HorizontalAlign = "center"
})
            </div>
        </div>
    </div>
</div>